.TH "TCRTEST" 1 "2010-08-05" "Man Page" "Tokyo Tyrant"

.SH NAME
tcrtest \- test cases of the remote database API

.SH DESCRIPTION
.PP
The command `\fBtcrtest\fR' is a utility for facility test and performance test.  This command is used in the following format.  `\fIhost\fR' specifies the host name of the server.  `\fIrnum\fR' specifies the number of iterations.
.PP
.RS
.br
\fBtcrtest write \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fR[\fB\-nr\fR]\fB \fR[\fB\-rnd\fR]\fB \fIhost\fB \fIrnum\fB\fR
.RS
Store records with keys of 8 bytes.  They change as `00000001', `00000002'...
.RE
.br
\fBtcrtest read \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fR[\fB\-mul \fInum\fB\fR]\fB \fR[\fB\-rnd\fR]\fB \fIhost\fB\fR
.RS
Retrieve all records of the database above.
.RE
.br
\fBtcrtest remove \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fR[\fB\-rnd\fR]\fB \fIhost\fB\fR
.RS
Remove all records of the database above.
.RE
.br
\fBtcrtest rcat \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fR[\fB\-shl \fInum\fB\fR]\fB \fR[\fB\-dai\fR|\fB\-dad\fR]\fB \fR[\fB\-ext \fIname\fB\fR]\fB \fR[\fB\-xlr\fR|\fB\-xlg\fR]\fB \fIhost\fB \fIrnum\fB\fR
.RS
Store records with partway duplicated keys using concatenate mode.
.RE
.br
\fBtcrtest misc \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fIhost\fB \fIrnum\fB\fR
.RS
Perform miscellaneous test of various operations.
.RE
.br
\fBtcrtest wicked \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fIhost\fB \fIrnum\fB\fR
.RS
Perform updating operations of list and map selected at random.
.RE
.br
\fBtcrtest table \fR[\fB\-port \fInum\fB\fR]\fB \fR[\fB\-cnum \fInum\fB\fR]\fB \fR[\fB\-tout \fInum\fB\fR]\fB \fR[\fB\-exp \fInum\fB\fR]\fB \fIhost\fB \fIrnum\fB\fR
.RS
Perform miscellaneous test of the table extension.
.RE
.RE
.PP
Options feature the following.
.PP
.RS
\fB\-port \fInum\fR\fR : specify the port number.
.br
\fB\-cnum \fInum\fR\fR : specify the number of connections.
.br
\fB\-tout \fInum\fR\fR : specify the timeout of each session in seconds.
.br
\fB\-nr\fR : use the function `tcrdbputnr' instead of `tcrdbput'.
.br
\fB\-rnd\fR : select keys at random.
.br
\fB\-mul \fInum\fR\fR : specify the number of records for the mget command.
.br
\fB\-shl \fInum\fR\fR : use `tcrdbputshl' and specify the width.
.br
\fB\-dai\fR : use `tcrdbaddint' instead of `tcrdbputcat'.
.br
\fB\-dad\fR : use `tcrdbadddouble' instead of `tcrdbputcat'.
.br
\fB\-ext \fIname\fR\fR : call a script language extension function.
.br
\fB\-xlr\fR : perform record locking.
.br
\fB\-xlg\fR : perform global locking.
.br
\fB\-exp \fInum\fR\fR : specify the lifetime of expiration test.
.br
.RE
.PP
If the port number is not more than 0, UNIX domain socket is used and the path of the socket file is specified by the host parameter.  This command returns 0 on success, another on failure.

.SH SEE ALSO
.PP
.BR ttserver (1),
.BR ttultest (1),
.BR ttulmgr (1),
.BR tcrmttest (1),
.BR tcrmgr (1),
.BR ttutil (3),
.BR tcrdb (3)
